

#include "UdpServer.hpp"
#include <memory>


int main(int argc, char* argv[])
{
    if (argc != 2)
    {
        std::cout << "Usage: " << argv[0] << " Local-Port" << std::endl;
        exit(0);
    }
    in_port_t port = std::stoi(argv[1]);

    // in_port_t port = 8899;
    // std::string ip = "127.0.0.1";  // 本主机（本地环回） -> localhost 

    EnableScreen();
    std::unique_ptr<UdpServer> usvr = std::make_unique<UdpServer>(port);  // C++14 的标准 
    usvr->InitServer();
    usvr->Start();
    return 0;
}

